{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "8278e544-c48b-4f34-a151-9b58ac31ae19",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "a=3, c=7\n"
     ]
    }
   ],
   "source": [
    "func tupleFn() (x, y, z int) {\n",
    "    return 3, 5, 7\n",
    "}\n",
    "\n",
    "var a, _, c = tupleFn()\n",
    "\n",
    "%%\n",
    "fmt.Printf(\"a=%d, c=%d\\n\", a, c)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "621d6604-e016-40a9-9ccd-734747e70187",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<h3>Memorized Definitions</h3>\n"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "data": {
      "text/html": [
       "<h4>Variables</h4>\n",
       "<ul>\n",
       "<li><pre>_~835760</pre></li>\n",
       "<li><pre>a</pre></li>\n",
       "<li><pre>c</pre></li>\n",
       "</ul>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "data": {
      "text/html": [
       "<h4>Functions</h4>\n",
       "<ul>\n",
       "<li><pre>tupleFn</pre></li>\n",
       "</ul>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "%ls"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "bfdcc7f3-a282-4db9-a0dd-e8e58362fd9e",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "c=1.5\n"
     ]
    }
   ],
   "source": [
    "var c = float32(1.5)\n",
    "\n",
    "%%\n",
    "fmt.Printf(\"c=%g\\n\", c)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "9ba8abf4-e15c-488b-a55d-740aaf24e1b9",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      ". key \"a\" not found in any definition, not removed\n"
     ]
    }
   ],
   "source": [
    "// Definition of `a` must have disappeared, when c was redefined.\n",
    "%rm a"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Go (gonb)",
   "language": "go",
   "name": "gonb"
  },
  "language_info": {
   "codemirror_mode": "",
   "file_extension": ".go",
   "mimetype": "text/x-go",
   "name": "go",
   "nbconvert_exporter": "",
   "pygments_lexer": "",
   "version": "go1.25.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
